1. Field of the Invention
The present invention relates to a moving body, which moves due to a motor as a source of power, a robot moving by actuating a plurality of legs using a motor as a source of power, and a program to give various controlling functions to each of the moving body and the robot.
2. Description of the Related Art
Conventionally, the operation of this moving body is controlled in such a manner that a main control unit transmits a desired angle of a joint of a moving body such as an arm robot to be driven by a motor to a motor control unit via a communication line, and the motor control unit controls power supply to the motor so that a joint angle of the moving body coincides with this desired angle.
In addition, a technical method to detect that the current supply to the motor as the source of power of a leg type moving robot is not in a predetermined range as an abnormality of this motor is proposed (for example, refer to column [0102], JP-A-2003-211379). Further, according to the robot having an arm moving due to a servomotor as a source of power, a technical method to variably set a threshold of the motor current in accordance with a motor commanding value in order to detect the abnormality such as the excessive current supply to the motor or the like with a high degree of accuracy is proposed (for example, refer to column [0005], JP-A-2001-022446).
However, due to a disturbance noise incorporation or the like in a network inside the robot, in the case that an abnormality such that a communication of the desired angle from the main control unit to the motor control unit is temporarily interrupted is generated, the following inconvenience occurs. This inconvenience will be described below with reference to FIG. 6.
If this communication is interrupted at time t1, as shown in FIG. 6A, even as a primary desired angle θT1 to be set by the main control unit has been continuously changed, as shown in FIG. 6B, a secondary desired angle θT2 stored and held by the motor control unit is maintained at a value θT2 (t1) and at time t1.
After that, when this communication is restored at time t2, as shown in FIG. 6B, in the secondary desired angle θT2, a step wise change δθT (=θT2(t2)−θT2 (t1)) occurs. In this time, in order to resolve the change δθT and coincide an actual angle θ with the secondary desired angle θT2, as shown in FIG. 6C, a motor current I is changed into a shape like a pulse with a height δI from time t2 to time t3. Thereby, as shown in FIG. 6D, the actual angle θ is controlled so as to coincide with the primary desired angle θT1 that is set by the main control unit.
Since the current supply to the motor is changed into a shape like a pulse in this way, a moving pattern of the robot cannot be expected and it is feared that the behavior of the robot after that suffers from an adverse affect. In addition, determining that an abnormality occurs in the power supply to the motor by the control system, it is feared that the power supply to the motor is stopped and the operation of the robot is stopped.